foreach $n (1..10) {
    print sprintf("%3d-%03d\n", $n);
}
